<template>
  <el-dialog :model-value="dialogVisible" title="Tips" width="30%" @close="close">
    <template #header>添加代办</template>
    <el-form>
      <el-form-item label="内容">
        <el-input v-model="form.content" />
      </el-form-item>
      <el-form-item label="时间">
        <el-date-picker v-model="form.date" type="date" placeholder="Pick a day" />
      </el-form-item>
    </el-form>
    <template #footer>
      <span class="dialog-footer">
        <el-button type="primary" @click="addBtn">
          添加
        </el-button>
      </span>
    </template>
  </el-dialog>
</template>

<script>
export default {
  name: '',
  components: {},
  props: {
    dialogVisible: {
      type: Boolean,
      default: false
    }
  },
  data () {
    return {
      // dialogVisible: true
      form: {
        content: '',
        date: null
      }
    }
  },
  created () { },
  mounted () { },
  methods: {
    close () {
      this.$emit('update:dialogVisible', false)
    },
    addBtn () {
      this.$emit('addList', this.form)
    },
  }

}
</script>

<style scoped lang="less"></style>